package io.renren.modules.app.api;

import io.renren.common.utils.PageUtils;
import io.renren.common.utils.R;
import io.renren.modules.app.service.ApiShopService;
import io.swagger.annotations.Api;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

/**
 * 商铺api
 * @author zzh
 * @email 862583291@qq.com
 * @date 2019-1-16 12:27
 */
@Api("商铺api")
@RestController
@RequestMapping("/app/v1/shop")
public class ApiShopController {

  @Autowired
  private ApiShopService shopService;

  /**
   * 条件查询加分页
   */
  @GetMapping("/list")
  public R list(@RequestParam Map<String, Object> params){
    PageUtils page = shopService.queryPage(params);
    return R.ok().put("page", page);
  }
}
